package cn.westv.scps.service.bikeowner;

import java.io.Serializable;
import java.util.Collection;
import java.util.List;

import cn.westv.scps.domain.BikeOwnerEntity;
import cn.westv.scps.utils.Page;

public interface IBikeOwnerService {

	// 查询所有，带条件查询
	public List<BikeOwnerEntity> find(String hql, Class<BikeOwnerEntity> entityClass, Object[] params);

	// 获取一条记录
	public BikeOwnerEntity get(Class<BikeOwnerEntity> entityClass, Serializable id);

	// 分页查询，将数据封装到一个page分页工具类对象
	public Page<BikeOwnerEntity> findPage(String hql, Page<BikeOwnerEntity> page, Class<BikeOwnerEntity> entityClass,
			Object[] params);

	// 新增和修改保存
	public void saveOrUpdate(BikeOwnerEntity entity);

	// 批量新增和修改保存
	public void saveOrUpdateAll(Collection<BikeOwnerEntity> entitys);

	// 单条删除，按id
	public void deleteById(Class<BikeOwnerEntity> entityClass, Serializable id);

	// 批量删除
	public void delete(Class<BikeOwnerEntity> entityClass, Serializable[] ids);

	// 执行SQL查询
	public List<BikeOwnerEntity> querySQL(String SQL, Object[] params, Class<BikeOwnerEntity> entityClass);

	// 根据电话查询用户
	public BikeOwnerEntity findByMobile(String mobile);


}
